﻿Imports System.IO

Class MainWindow
    Private Sub MainWindow_Initialized(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Initialized
        'Set the Minunin size of mainwindow
        Me.MinHeight = "570"
        Me.MinWidth = "1024"
        Me.Title = My.Application.Info.ProductName
        'Checks what OS you are using as some of the features in the system tab are not supported on XP
        If System.Environment.OSVersion.Version.Major.ToString < 6 Then
            'System Tab Hidden
            tbiSys.Visibility = Windows.Visibility.Collapsed
        Else
            'Compatibility System Tab Hidden
            tbiSysComp.Visibility = Windows.Visibility.Hidden
        End If

        'Check if intune exists either hide cmb_intune or tblEmail depending on outcome.
        If My.Computer.FileSystem.FileExists(Environment.GetFolderPath(Environment.SpecialFolder.ProgramFiles) & "\Microsoft\OnlineManagement\Client UI\cltui.exe") = True Then
            txtIntuneService.Foreground = Brushes.DarkGreen
            txtIntuneService.Text = "You are joined to our Intune Service"
            tblIntuneInfo.Text = "Click the image to find out more infomation about Windows Intune."
            cmb_Intune.Visibility = Windows.Visibility.Visible
            tblEmail.Visibility = Windows.Visibility.Hidden
        Else
            txtIntuneService.Foreground = Brushes.Red
            txtIntuneService.Text = "You are not joined to our Intune Service"
            cmb_Intune.Visibility = Windows.Visibility.Hidden
        End If
    End Sub

    Private Sub Window_Loaded(ByVal sender As System.Object, ByVal e As System.Windows.RoutedEventArgs) Handles MyBase.Loaded
        tblUserProfile.Text = Environment.UserName
        tblWelcome.Text = "Welcome " & Environment.UserName & ", to your Computer!"
    End Sub

    Private Sub imgDocuments_MouseLeftButtonDown(ByVal sender As Object, ByVal e As System.Windows.Input.MouseButtonEventArgs) Handles imgDocuments.MouseLeftButtonDown
        'Start Explorer, navigate to Documents Folder
        Process.Start(My.Computer.FileSystem.SpecialDirectories.MyDocuments)
    End Sub

    Private Sub imgUserFolder_MouseLeftButtonDown(ByVal sender As Object, ByVal e As System.Windows.Input.MouseButtonEventArgs) Handles imgUserFolder.MouseLeftButtonDown
        'Start Explorer, navigate to UserProfile Folder
        Process.Start(Environment.GetFolderPath(Environment.SpecialFolder.UserProfile))
    End Sub

    Private Sub imgMusic_MouseLeftButtonDown(ByVal sender As Object, ByVal e As System.Windows.Input.MouseButtonEventArgs) Handles imgMusic.MouseLeftButtonDown
        'Start Explorer, navigate to Music Folder
        Process.Start(My.Computer.FileSystem.SpecialDirectories.MyMusic)
    End Sub

    Private Sub imgPictures_MouseLeftButtonDown(ByVal sender As Object, ByVal e As System.Windows.Input.MouseButtonEventArgs) Handles imgPictures.MouseLeftButtonDown
        'Start Explorer, navigate to Pictures Folder
        Process.Start(My.Computer.FileSystem.SpecialDirectories.MyPictures)
    End Sub

    Private Sub imgLibraries_MouseLeftButtonDown(ByVal sender As Object, ByVal e As System.Windows.Input.MouseButtonEventArgs) Handles imgLibraries.MouseLeftButtonDown
        'Start Explorer, navigate to Libraries Folder
        Process.Start(Environment.GetFolderPath(Environment.SpecialFolder.Windows) & "\explorer.exe")
    End Sub

    Private Sub imgGoogle_MouseLeftButtonDown(ByVal sender As Object, ByVal e As System.Windows.Input.MouseButtonEventArgs) Handles imgGoogle.MouseLeftButtonDown
        'Start Default browser and navigate to website
        Process.Start("http://www.google.com")
    End Sub

    Private Sub imgFacebook_MouseLeftButtonDown(ByVal sender As Object, ByVal e As System.Windows.Input.MouseButtonEventArgs) Handles imgFacebook.MouseLeftButtonDown
        'Start Default browser and navigate to website
        Process.Start("http://www.facebook.com")
    End Sub

    Private Sub imgHotmail_MouseLeftButtonDown(ByVal sender As Object, ByVal e As System.Windows.Input.MouseButtonEventArgs) Handles imgHotmail.MouseLeftButtonDown
        'Start Default browser and navigate to website
        Process.Start("http://mail.live.com")
    End Sub

    Private Sub imgGmail_MouseLeftButtonDown(ByVal sender As Object, ByVal e As System.Windows.Input.MouseButtonEventArgs) Handles imgGmail.MouseLeftButtonDown
        'Start Default browser and navigate to website
        Process.Start("http://mail.google.com")
    End Sub
    Private Sub imgPPT_MouseLeftButtonDown(ByVal sender As Object, ByVal e As System.Windows.Input.MouseButtonEventArgs) Handles imgPPT.MouseLeftButtonDown
        'Check if file exists if it doesn't the generate MessageBox. If it does start the program
        If My.Computer.FileSystem.FileExists(Environment.GetFolderPath(Environment.SpecialFolder.ProgramFiles) & "\Microsoft Office\Office14\POWERPNT.exe") = True Then
            Process.Start(Environment.GetFolderPath(Environment.SpecialFolder.ProgramFiles) & "\Microsoft Office\Office14\POWERPNT.exe")
        ElseIf My.Computer.FileSystem.FileExists(Environment.GetFolderPath(Environment.SpecialFolder.ProgramFilesX86) & "\Microsoft Office\Office14\POWERPNT.exe") = True Then
            Process.Start(Environment.GetFolderPath(Environment.SpecialFolder.ProgramFilesX86) & "\Microsoft Office\Office14\POWERPNT.exe")
        ElseIf My.Computer.FileSystem.FileExists(Environment.GetFolderPath(Environment.SpecialFolder.ProgramFiles) & "\LibreOffice 3.4\program\simpress.exe") = True Then
            Process.Start(Environment.GetFolderPath(Environment.SpecialFolder.ProgramFiles) & "\LibreOffice 3.4\program\simpress.exe")
        Else : If MsgBox("This program is not installed. Would you Like to install the free LibreOffice Suite?", MsgBoxStyle.Information + MsgBoxStyle.YesNo, "TG Center") = MsgBoxResult.Yes Then
                Process.Start("http://www.libreoffice.org/")
            End If
        End If
    End Sub

    Private Sub imgVLC_MouseLeftButtonDown(ByVal sender As Object, ByVal e As System.Windows.Input.MouseButtonEventArgs) Handles imgVLC.MouseLeftButtonDown
        'Check if file exists if it doesn't the generate MessageBox. If it does start the program
        If My.Computer.FileSystem.FileExists(Environment.GetFolderPath(Environment.SpecialFolder.ProgramFiles) & "\VideoLAN\VLC\vlc.exe") Then
            Process.Start(Environment.GetFolderPath(Environment.SpecialFolder.ProgramFiles) & "\VideoLAN\VLC\vlc.exe")
        ElseIf My.Computer.FileSystem.FileExists(Environment.GetFolderPath(Environment.SpecialFolder.ProgramFilesX86) & "\VideoLAN\VLC\vlc.exe") = True Then
            Process.Start(Environment.GetFolderPath(Environment.SpecialFolder.ProgramFilesX86) & "\VideoLAN\VLC\vlc.exe")
        ElseIf My.Computer.FileSystem.FileExists(Environment.GetFolderPath(Environment.SpecialFolder.ProgramFiles) & "\Windows Media Player\WMPlayer.exe") = True Then
            Process.Start(Environment.GetFolderPath(Environment.SpecialFolder.ProgramFiles) & "\Windows Media Player\WMPlayer.exe")
        Else : If MsgBox("This program is not installed. Would you like to install it?", MsgBoxStyle.Information + MsgBoxStyle.YesNo, "TG Center") = MsgBoxResult.Yes Then
                Process.Start("http://www.videolan.org/vlc/download-windows.html/")
            End If
        End If
    End Sub

    Private Sub imgFirefox_MouseLeftButtonDown(ByVal sender As Object, ByVal e As System.Windows.Input.MouseButtonEventArgs) Handles imgFirefox.MouseLeftButtonDown
        'Check if file exists if it doesn't the generate MessageBox. If it does start the program
        If My.Computer.FileSystem.FileExists(Environment.GetFolderPath(Environment.SpecialFolder.ProgramFiles) & "\Mozilla Firefox\firefox.exe") = True Then
            Process.Start(Environment.GetFolderPath(Environment.SpecialFolder.ProgramFiles) & "\Mozilla Firefox\firefox.exe")
        ElseIf My.Computer.FileSystem.FileExists(Environment.GetFolderPath(Environment.SpecialFolder.ProgramFiles) & "\Mozilla Firefox\firefox.exe") = False Then
            If MsgBox("This program is not installed. Would you like to install it?", MsgBoxStyle.Information + MsgBoxStyle.YesNo, "TG Center") = MsgBoxResult.Yes Then
                Process.Start("http://www.mozilla.com/en-US/firefox/new/")
            End If
        End If
    End Sub

    Private Sub imgPaint_MouseLeftButtonDown(ByVal sender As Object, ByVal e As System.Windows.Input.MouseButtonEventArgs) Handles imgPaint.MouseLeftButtonDown
        Process.Start(Environment.GetFolderPath(Environment.SpecialFolder.System) & "\mspaint.exe")
    End Sub

    Private Sub imgReader_MouseLeftButtonDown(ByVal sender As Object, ByVal e As System.Windows.Input.MouseButtonEventArgs) Handles imgReader.MouseLeftButtonDown
        'Check if file exists if it doesn't the generate MessageBox. If it does start the program
        If My.Computer.FileSystem.FileExists(Environment.GetFolderPath(Environment.SpecialFolder.ProgramFiles) & "\Adobe\Reader 10.0\Reader\AcroRd32.exe") = True Then
            Process.Start(Environment.GetFolderPath(Environment.SpecialFolder.ProgramFiles) & "\Adobe\Reader 10.0\Reader\AcroRd32.exe")
        ElseIf My.Computer.FileSystem.FileExists(Environment.GetFolderPath(Environment.SpecialFolder.ProgramFilesX86) & "\Adobe\Reader 10.0\Reader\AcroRd32.exe") = True Then
            Process.Start(Environment.GetFolderPath(Environment.SpecialFolder.ProgramFilesX86) & "\Adobe\Reader 10.0\Reader\AcroRd32.exe")
        Else : If MsgBox("This program is not installed. Would you like to install it?", MsgBoxStyle.Information + MsgBoxStyle.YesNo, "TG Center") = MsgBoxResult.Yes Then
                Process.Start("http://get.adobe.com/reader/")
            End If
        End If
    End Sub

    Private Sub imgWLM_MouseLeftButtonDown(ByVal sender As Object, ByVal e As System.Windows.Input.MouseButtonEventArgs) Handles imgWLM.MouseLeftButtonDown
        'Check if file exists if it doesn't the generate MessageBox. If it does start the program
        If My.Computer.FileSystem.FileExists(Environment.GetFolderPath(Environment.SpecialFolder.ProgramFiles) & "\Windows Live\Messenger\msnmsgr.exe") = True Then
            Process.Start(Environment.GetFolderPath(Environment.SpecialFolder.ProgramFiles) & "\Windows Live\Messenger\msnmsgr.exe")
        ElseIf My.Computer.FileSystem.FileExists(Environment.GetFolderPath(Environment.SpecialFolder.ProgramFilesX86) & "\Windows Live\Messenger\msnmsgr.exe") = True Then
            Process.Start(Environment.GetFolderPath(Environment.SpecialFolder.ProgramFilesX86) & "\Windows Live\Messenger\msnmsgr.exe")
        Else : If MsgBox("This program is not installed. Would you like to Install Windows Live Essentials?", MsgBoxStyle.Information + MsgBoxStyle.YesNo, "TG Center") = MsgBoxResult.Yes Then
                Process.Start("http://explore.live.com/windows-live-essentials?os=other")
            End If
        End If
    End Sub

    Private Sub imgMail_MouseLeftButtonDown(ByVal sender As Object, ByVal e As System.Windows.Input.MouseButtonEventArgs) Handles imgMail.MouseLeftButtonDown
        'Check if file exists if it doesn't the generate MessageBox. If it does start the program
        If My.Computer.FileSystem.FileExists(Environment.GetFolderPath(Environment.SpecialFolder.ProgramFiles) & "\Microsoft\OnlineManagement\ClientUI\cltui.exe") = True Then
            Process.Start(Environment.GetFolderPath(Environment.SpecialFolder.ProgramFiles) & "\Microsoft\OnlineManagement\ClientUI\cltui.exe")
        Else : If MsgBox("This program is not installed. Would you like to Install Windows Live Essentials?", MsgBoxStyle.Information + MsgBoxStyle.YesNo, "TG Center") = MsgBoxResult.Yes Then
                Process.Start("http://explore.live.com/windows-live-essentials?os=other")
            End If
        End If
    End Sub

    Private Sub imgUsers_MouseLeftButtonDown(ByVal sender As Object, ByVal e As System.Windows.Input.MouseButtonEventArgs) Handles imgUsers.MouseLeftButtonDown
        Process.Start(Environment.GetFolderPath(Environment.SpecialFolder.System) & "\control.exe", "userpasswords")
    End Sub

    Private Sub imgPrograms_MouseLeftButtonDown(ByVal sender As Object, ByVal e As System.Windows.Input.MouseButtonEventArgs) Handles imgPrograms.MouseLeftButtonDown
        Process.Start(Environment.GetFolderPath(Environment.SpecialFolder.System) & "\control.exe", "/name Microsoft.ProgramsAndFeatures")
    End Sub

    Private Sub imgDiskClean_MouseLeftButtonDown(ByVal sender As Object, ByVal e As System.Windows.Input.MouseButtonEventArgs) Handles imgDiskClean.MouseLeftButtonDown
        Process.Start(Environment.GetFolderPath(Environment.SpecialFolder.System) & "\cleanmgr.exe")
    End Sub

    Private Sub imgAppearence_MouseLeftButtonDown(ByVal sender As Object, ByVal e As System.Windows.Input.MouseButtonEventArgs) Handles imgAppearence.MouseLeftButtonDown
        Process.Start(Environment.GetFolderPath(Environment.SpecialFolder.System) & "\control.exe", "/name Microsoft.Personalization")
    End Sub

    Private Sub imgUpdate_MouseLeftButtonDown(ByVal sender As Object, ByVal e As System.Windows.Input.MouseButtonEventArgs) Handles imgUpdate.MouseLeftButtonDown
        Process.Start(Environment.GetFolderPath(Environment.SpecialFolder.System) & "\control.exe", "/name Microsoft.WindowsUpdate")
    End Sub

    Private Sub imgNetwork_MouseLeftButtonDown(ByVal sender As Object, ByVal e As System.Windows.Input.MouseButtonEventArgs) Handles imgNetwork.MouseLeftButtonDown
        Process.Start(Environment.GetFolderPath(Environment.SpecialFolder.System) & "\control.exe", "/name Microsoft.NetworkAndSharingCenter")
    End Sub

    Private Sub imgAntiVirus_MouseLeftButtonDown(ByVal sender As Object, ByVal e As System.Windows.Input.MouseButtonEventArgs) Handles imgAntiVirus.MouseLeftButtonDown
        'Check if file exists if it doesn't the generate MessageBox. If it does start the program
        If My.Computer.FileSystem.FileExists(Environment.GetFolderPath(Environment.SpecialFolder.ProgramFiles) & "\Microsoft Security Client\msseces.exe") = True Then
            Process.Start(Environment.GetFolderPath(Environment.SpecialFolder.ProgramFiles) & "\Microsoft Security Client\msseces.exe")
        Else : If MsgBox("You do not have a supported antivirus installed. Would you like to install Microsoft Security Essentials?", MsgBoxStyle.Information + MsgBoxStyle.YesNo, "TG Center") = MsgBoxResult.Yes Then
                Process.Start("http://www.microsoft.com/en-au/security_essentials/default.aspx/")
            End If
        End If
    End Sub

    Private Sub imgFirewall_MouseLeftButtonDown(ByVal sender As Object, ByVal e As System.Windows.Input.MouseButtonEventArgs) Handles imgFirewall.MouseLeftButtonDown
        Process.Start(Environment.GetFolderPath(Environment.SpecialFolder.System) & "\control.exe", "/name Microsoft.WindowsFirewall")
    End Sub

    Private Sub imgDefault_MouseLeftButtonDown(ByVal sender As Object, ByVal e As System.Windows.Input.MouseButtonEventArgs) Handles imgDefault.MouseLeftButtonDown
        Process.Start(Environment.GetFolderPath(Environment.SpecialFolder.System) & "\control.exe", "/name Microsoft.DefaultPrograms")
    End Sub

    Private Sub imgDevices_MouseLeftButtonDown(ByVal sender As Object, ByVal e As System.Windows.Input.MouseButtonEventArgs) Handles imgDevices.MouseLeftButtonDown
        Process.Start(Environment.GetFolderPath(Environment.SpecialFolder.System) & "\control.exe", "/name Microsoft.DevicesAndPrinters")
    End Sub

    Private Sub imgChrome_MouseLeftButtonDown(ByVal sender As Object, ByVal e As System.Windows.Input.MouseButtonEventArgs) Handles imgChrome.MouseLeftButtonDown
        'Check if file exists if it doesn't the generate MessageBox. If it does start the program
        If My.Computer.FileSystem.FileExists(Environment.GetFolderPath(Environment.SpecialFolder.LocalApplicationData) & "\Google\Chrome\Application\chrome.exe") = True Then
            Process.Start(Environment.GetFolderPath(Environment.SpecialFolder.LocalApplicationData) & "\Google\Chrome\Application\chrome.exe")
        Else : If MsgBox("This Program is not installed. Would you Like to install it?", MsgBoxStyle.Information + MsgBoxStyle.YesNo, "TG Center") = MsgBoxResult.Yes Then
                Process.Start("http://www.google.com/chrome/eula.html?extra=devchannel&platform=win")
            End If
        End If
    End Sub

    Private Sub imgSkype_MouseLeftButtonDown(ByVal sender As Object, ByVal e As System.Windows.Input.MouseButtonEventArgs) Handles imgSkype.MouseLeftButtonDown
        'Check if file exists if it doesn't the generate MessageBox. If it does start the program
        If My.Computer.FileSystem.FileExists(Environment.GetFolderPath(Environment.SpecialFolder.ProgramFiles) & "\Skype\Phone\skype.exe") = True Then
            Process.Start(Environment.GetFolderPath(Environment.SpecialFolder.ProgramFiles) & "\Skype\Phone\skype.exe")
        Else : If MsgBox("This program is not installed. Would you like to install it?", MsgBoxStyle.Information + MsgBoxStyle.YesNo, "TG Center") = MsgBoxResult.Yes Then
                Process.Start("http://www.skype.com/intl/en/get-skype/on-your-computer/windows/")
            End If
        End If
    End Sub

    Private Sub tblUpdates_MouseLeftButtonDown(ByVal sender As Object, ByVal e As System.Windows.Input.MouseButtonEventArgs) Handles tblUpdates.MouseLeftButtonDown
        Process.Start("http://tgapps.codeplex.com/")
    End Sub

    Private Sub imgWord_MouseLeftButtonDown(ByVal sender As Object, ByVal e As System.Windows.Input.MouseButtonEventArgs) Handles imgWord.MouseLeftButtonDown
        'Check if file exists if it doesn't the generate MessageBox. If it does start the program
        If My.Computer.FileSystem.DirectoryExists(Environment.GetFolderPath(Environment.SpecialFolder.ProgramFiles) & "\Microsoft Office\Office14") = True Then
            Process.Start(Environment.GetFolderPath(Environment.SpecialFolder.ProgramFiles) & "\Microsoft Office\Office14\WINWORD.exe")
        ElseIf My.Computer.FileSystem.DirectoryExists(Environment.GetFolderPath(Environment.SpecialFolder.ProgramFiles) & "\Microsoft Office\Office12") = True Then
            Process.Start(Environment.GetFolderPath(Environment.SpecialFolder.ProgramFiles) & "\Microsoft Office\Office12\WINWORD.exe")
        ElseIf My.Computer.FileSystem.DirectoryExists(Environment.GetFolderPath(Environment.SpecialFolder.ProgramFiles) & "\LibreOffice 3.4\program") = True Then
            Process.Start(Environment.GetFolderPath(Environment.SpecialFolder.ProgramFiles) & "\LibreOffice 3.4\program\swriter.exe")
        Else : If MsgBox("This program is not installed. Would you Like to install the free LibreOffice Suite?", MsgBoxStyle.Information + MsgBoxStyle.YesNo, "TG Center") = MsgBoxResult.Yes Then
                Process.Start("http://www.libreoffice.org/")
            End If
        End If

    End Sub

    Private Sub tblAbout_MouseLeftButtonDown(ByVal sender As Object, ByVal e As System.Windows.Input.MouseButtonEventArgs) Handles tblAbout.MouseLeftButtonDown
        'Opens a new WPF Window
        'frm.show 1 deprecated in this version, so we ShowDialog instead
        Dim frm As New About
        frm.ShowDialog()
    End Sub

    Private Sub imgInfoIntune_Initialized(ByVal sender As Object, ByVal e As System.EventArgs) Handles imgInfoIntune.Initialized
        imgInfoIntune.ToolTip = "Click here to find out more about Windows Intune"
    End Sub

    Private Sub cmb_Intune_Click_1(ByVal sender As System.Object, ByVal e As System.Windows.RoutedEventArgs) Handles cmb_Intune.Click
        Process.Start(Environment.GetFolderPath(Environment.SpecialFolder.ProgramFiles) & "\Microsoft\OnlineManagement\Client UI\cltui.exe")
    End Sub

    Private Sub imgUsersC_MouseLeftButtonDown(ByVal sender As Object, ByVal e As System.Windows.Input.MouseButtonEventArgs) Handles imgUsersC.MouseLeftButtonDown
        Process.Start(Environment.GetFolderPath(Environment.SpecialFolder.System) & "\control.exe", "userpasswords")
    End Sub

    Private Sub imgProgramsC_MouseLeftButtonDown(ByVal sender As Object, ByVal e As System.Windows.Input.MouseButtonEventArgs) Handles imgProgramsC.MouseLeftButtonDown
        Process.Start(Environment.GetFolderPath(Environment.SpecialFolder.System) & "\control.exe", "appwiz.cpl")
    End Sub

    Private Sub imgDiskCleanC_MouseLeftButtonDown(ByVal sender As Object, ByVal e As System.Windows.Input.MouseButtonEventArgs) Handles imgDiskCleanC.MouseLeftButtonDown
        Process.Start(Environment.GetFolderPath(Environment.SpecialFolder.System) & "\cleanmgr.exe")
    End Sub

    Private Sub imgAppearenceC_MouseLeftButtonDown(ByVal sender As Object, ByVal e As System.Windows.Input.MouseButtonEventArgs) Handles imgAppearenceC.MouseLeftButtonDown
        Process.Start(Environment.GetFolderPath(Environment.SpecialFolder.System) & "\control.exe", "desktop")
    End Sub

    Private Sub imgUpdateC_MouseLeftButtonDown(ByVal sender As Object, ByVal e As System.Windows.Input.MouseButtonEventArgs) Handles imgUpdateC.MouseLeftButtonDown
        'uses the default browser to navigate to website
        Process.Start("www.update.microsoft.com")
    End Sub

    Private Sub imgAntiVirusC_MouseLeftButtonDown(ByVal sender As Object, ByVal e As System.Windows.Input.MouseButtonEventArgs) Handles imgAntiVirusC.MouseLeftButtonDown
        If My.Computer.FileSystem.FileExists(Environment.GetFolderPath(Environment.SpecialFolder.ProgramFiles) & "\Microsoft Security Client\msseces.exe") = True Then
            Process.Start(Environment.GetFolderPath(Environment.SpecialFolder.ProgramFiles) & "\Microsoft Security Client\msseces.exe")
        Else : If MsgBox("You do not have a supported antivirus installed. Would you like to install Microsoft Security Essentials?", MsgBoxStyle.Information + MsgBoxStyle.YesNo, "TG Center") = MsgBoxResult.Yes Then
                Process.Start("http://www.microsoft.com/en-au/security_essentials/default.aspx/")
            End If
        End If
    End Sub

    Private Sub imgFirewallC_MouseLeftButtonDown(ByVal sender As Object, ByVal e As System.Windows.Input.MouseButtonEventArgs) Handles imgFirewallC.MouseLeftButtonDown
        Process.Start(Environment.GetFolderPath(Environment.SpecialFolder.System) & "\control.exe", "firewall.cpl")
    End Sub

    Private Sub imgDefaultC_MouseLeftButtonDown(ByVal sender As Object, ByVal e As System.Windows.Input.MouseButtonEventArgs) Handles imgDefaultC.MouseLeftButtonDown
        Process.Start(Environment.GetFolderPath(Environment.SpecialFolder.System) & "\control.exe", "appwiz.cpl,,3")
    End Sub

    Private Sub imgDevicesC_MouseLeftButtonDown(ByVal sender As Object, ByVal e As System.Windows.Input.MouseButtonEventArgs) Handles imgDevicesC.MouseLeftButtonDown
        Process.Start(Environment.GetFolderPath(Environment.SpecialFolder.System) & "\control.exe", "printers")
    End Sub

    Private Sub imgNetworkC_MouseLeftButtonDown(ByVal sender As Object, ByVal e As System.Windows.Input.MouseButtonEventArgs) Handles imgNetworkC.MouseLeftButtonDown
        Process.Start(Environment.GetFolderPath(Environment.SpecialFolder.System) & "\control.exe", "netconnections")
    End Sub

    Private Sub cmb_Intune_Click(ByVal sender As System.Object, ByVal e As System.Windows.RoutedEventArgs) Handles cmb_Intune.Click
        Process.Start(Environment.GetFolderPath(Environment.SpecialFolder.ProgramFiles) & "\Microsoft\OnlineManagement\Client UI\cltui.exe")
    End Sub

    Private Sub imgInfoIntune_MouseLeftButtonDown(ByVal sender As Object, ByVal e As System.Windows.Input.MouseButtonEventArgs) Handles imgInfoIntune.MouseLeftButtonDown
        'uses the default browser to navigate to website
        Process.Start("http://www.microsoft.com/windows/windowsintune/pc-management.aspx")
    End Sub

    Private Sub tblEmail_MouseLeftButtonDown(ByVal sender As Object, ByVal e As System.Windows.Input.MouseButtonEventArgs) Handles tblEmail.MouseLeftButtonDown
        'starts the default email client
        Try
            Process.Start("mailto:computer.repairs.tg@gmail.com")

        Catch

        Finally
            MsgBox("The default email client is not configured", MsgBoxStyle.OkOnly & vbExclamation, "Error")
        End Try
    End Sub
End Class
